Copyright: VBTrace 96 Copyright(C) 1994 - 1996 Chuck Stuart


Contents
Getting Started With VBTrace 96:

 Installing VBTrace 96

About VBTrace 96:

 What Is VBTrace 96

 What VBTrace 96 Does

 The VBTrace 96 Screen

VBTrace 96 Features:

 Standard VBTrace 96 Features

 Additional Features

 VBTrace Menus

Other Information:

 In Case Of A Problem

 Registering VBTrace 96


What Is VBTrace
What Is VBTrace 96:

VBTrace 96 is a utility program designed primarily to overcome the inability to obtain a listing of the procedures executed by a Visual Basic program in the order in which they are executed.  The standard step tracing provided with Visual Basic is fine for tracing code within a procedure, but is inadequate for tracing program flow from procedure to procedure.  Step tracing cannot follow idle time events such as SetFocus or input from the keyboard.  Using step tracing will, in many instances, actually change the order in which procedures are executed.

With VBTrace 96 you can easily:

•	Spot procedures which are being called accidentally or unnecessarily,

•	See the exact order in which procedures and events are executed.

•	See why a particular form takes so long to load

•	Know how many forms are loaded at any point in a program.

•	Tell if a procedure is being called recursively,

•	See which areas of your program use the most Windows resources.

•	See when each form is actually loaded and unloaded.

•	Track GDI, USER, and Global Memory usage from procedure to procedure.

•	Track disk space usage.

•	Set and track an unlimited number of watch variables.

•	Monitor the value of arguments being passed to procedures.

•	Pinpoint cascade events.

•	Find and remove duplicate files from your disk.

•	Time a procedure or group of procedures with millisecond accuracy.

•	Print formatted source code listings to a printer or disk file.

•	Automatically add Error Code to each procedure in a project.

•	Add line numbers to each executable statement in a project. This is convenient for locating errors in compiled programs.

•	Generate a cross reference listing showing all global, form level, and procedure level variables being used in the program and where each is referenced. Also shown are variables created but never referenced.

•	Generate a cross reference listing showing all procedures in the program and where each procedure is referenced. Also shown are procedures which are never referenced in the program.

•	Print your application's source code with different font type and size for the Headings, Procedure Names, Source Code, and Comments.

•	Find and safely remove duplicate files such as DLLs, VBXs, EXEs, etc.

•	List the procedures in your application sorted by procedure time consumed.

There are times in your Visual Basic program when the user clicks, tabs, or Alt/keys and you have no idea which procedures are executed and in what order.  With VBTrace 96, you always know.


What VBTrace Does
What VBTrace 96 Does:

VBTrace 96 automatically inserts trace code into each procedure in your Visual Basic program.  At least two lines are added to each procedure.  One to record when the procedure is entered and one for each exit point in the procedure.  VBTrace 96 also custom configures and adds the code module VBTRC96.BAS to the project MAK or VBP file.

During the execution of your program, the trace code sends the name of each procedure being entered or exited to the VBTRC96.BAS code module.  The code module then writes the name of the procedure and the name and value of any variables or resources being traced to the procedure trace file, VBTRC96.DAT.

VBTRC96.BAS is in text format.  PLEASE! do not make changes to the VBTRC96.BAS code module.  This code module is dynamically reprogramed 'on the fly' whenever changes are made to the VBTrace 96 configuration and VBTrace 96 expects it to be in the correct format.

Once procedure tracing is no longer required, VBTrace 96 may be used to automatically remove all trace code from your program and remove the VBTRC96.BAS code module from the project MAK or VBP file.


Screen

Click on any item above to see information on that item.


Standard Features
Standard VBTrace 96 Features:

 Trace Code Manager

 Watch Variables Manager

 Exceptions Manager

 Headings Collection

 Procedure Search

 Backup / Restore Project


Trace Code Manager

Click on any item above to see information on that item.

Trace code should be added whenever new procedures are added to the project. Trace code cannot be added to a running program.  If the selected program is already running, it will be automatically unloaded, trace code will be added. and the program will be reloaded.

After trace code has been added to the project, select the VB button on the toolbar to minimize VBTrace 96 and switch to the project being traced. While minimized, VBTrace 96 shows the available GDI, USER, and Global Heap memory.

After executing the desired portions of your program, switch back to VBTrace 96 and view the trace listing.  You may switch back and forth as often as desired. The trace listing will continue to grow until the project being traced is restarted or the trace listing is cleared.

It is unecessary to remove the trace code to return your project to normal operation.  Trace code is automatically disabled whenever VBTrace 96 is not running.


VariablesManager

Click on any item above to see information on that item.

IMPORTANT NOTE:  Variables which are passed directly to procedures are automatically displayed in the Procedures column of the VBTrace 96 listing.  Do not add these variables to the Watch Variables Collection.

Whenever a Watch Variable is added or modified, the new heading configuration is added to the Headings Collection.  A Watch Variable may be removed from the VBTrace 96 display at runtime by double clicking on the column containing the Watch Variable to be removed.

Global Variable Name:

When an Add operation is selected, the dropdown list contains the names of all global variables in the currently selected project. When Modify is selected, the dropdown list contains any previously selected global variables plus the default variables.

Global Variables Index:

If an array variable is selected, enter the index value into the Index box.  The Index must be either a numeric literal within the lower and upper bounds of the array or else an Index variable which is global in scope.

Column Heading:

Enter the name to appear at the top of the column in the VBTrace 96 listing.

Column Width:

Enter the column width in characters.  If the data or Column Heading exceeds the column width, they will be truncated.  NOTE, to resize a column in the VBTrace 96 grid at runtime, place the cursor on the column separator bar on the VBTrace 96 heading, the cursor will change to a small black cross, hold down the left mouse button and drag the column separator to the desired location.

Format String:

Enter any valid Visual Basic format string.  This is the only optional entry.

Data Alignment:

Select the alignment for the data to appear in this column.

Status:

The Status field determines whether the global variable being entered or modified will appear in the current heading. Enter a 1 to include it, enter 0 to remove it. The Status of any global variable may be changed at any time. Adding a new global variable to the current heading, or modifying an existing variable, will automatically add a new entry to the headings collection. This allows you to return to any previous heading with only a mouse click.


Exception Events

Click on any item above to see more information on that item.

The Exception Events feature allows you to flag procedures, events, or entire forms to not be included in the trace listing.

An example of an Exception Event might be a MouseMove event.  A MouseMove event could generate many llines in the trace listing but add no useful information to the debugging process.

Exception Events may be added or removed at any time.


Headings Collection

Click on any item above to see more information on that item.

Click on the 'H' button on the toolbar to view the available headings. The two headings shown above are created automatically in the original VBTrace 96 configuration. Each column is explained below.

•	Line Number: Used to track a particular procedure or procedures.

•	Previous Line Number: The line number where the current procedure was previously referenced. This is used to trace a procedure back through the listing.

•	Time: The time in milliseconds required to execute the current instance of this procedure. Shown on exit lines only.

•	Cum: Cumlative time to execute all instances of this procedure up to this point.

•	%: The percentage of total execution time up to this point used by this procedure.

•	The total execution time required by this project up to this time.

•	Enter:  The number of times, including this time, that the current procedure has been entered.

•	Exit: The number of times, including this time, this procedure has been exited.

•	Procedure Name: The name of the current procedure. Also shown in this column is the form name, whether the procedure is being entered or exited, and the value of each argument being passed to this procedure.


ProcedureSearch

Click on any item above for information on that item.

The Procedure Search feature may be used to search for a particular procedure, or the entry and exit points of a particular procedure. Press F3 to find the next occurrence of a search string.

Check the 'Match Case' check box to find only procedure names which exactly match the case of the search string.

Check the 'Match Whole Word Only' check box to find only procedure names which exactly match the search string.  If this box is not checked, all procedure names which begin with the search string will be displayed.


Backup Restore

Click on any item above to see more information on that item.

The Backup / Restore feature allows you to backup the project files before making changes to the source code. If a problem occurs, you can easily restore the project files to thei original condition. If the backup directory does not exist, VBTrace 96 will create it.

PROJECT: Select this option to backup only the files in the project MAK file.

DIRECTORY: Select this option to backup all files in the project directory. Files which are referenced in the project MAK file, but not located in the project directory, will not be backed up unless the PROJECT option is also selected.


Additional Features

 Reports Manager

 Error Code Manager

 Adding Line Numbers

 Printing Source Code

 Duplicate Files Manager

 Procedures Sorted By Time Required

 Format Source Code


ReportManager

Click on any item above for information on that item.

Three types of reports may be printed; Variables Cross Reference, Procedures Cross Reference, and a hard copy of the VBTrace 96 listing.

The VBTrace 96 listing report may be printed at any time. The 'Create Report' button must be selected to create the Cross Reference reports before printing. After creating the Cross Reference reports, use the report options to configure the desired report.

NOTE: Only a single pass is required to create the information for all report and cross reference listings.  After running 'Create Reports', the various options and check boxes may be used to configure the desired report or reports. It is not necessary to run Create Reports for each configuration.

The Variables Cross Reference report shows all variables which have been declared at either the global level, form level, or procedure level. The report shows all references to each variable, the procedures where the variables are referenced, and the number of times each variable is referenced. The report also identifies all variables which have been declared in the program but are never referenced in code. The unreferenced variables may be printed as a separate report.

The Procedures Cross Reference report shows all procedures in the project, where each procedure is referenced, and the number of times each procedure is referenced. The report also shows any procedures which are never referenced. The unreferenced procedures may be printed as a separate report.

The Variables Cross Reference and Procedures Cross Reference reports may be printed to the screen, printer, or to a disk file. A file name must be entered when printing to a disk file.

The trace report may be printed to the printer or to a disk file. The additional information shown on the VBTrace 96 Status Bar may be included in the report by checking the 'Include Resources' check box.

Click on the Printer Setup command button to set or change the default printer settings.

Click on the Screen Setup command button to set the appearance of reports printed to the screen.


ErrorCodeManager

Click on any item above to see more information on that item.

The VBTrace 96 Error Code Manager may be used to automatically add error code to, and remove error code from, each procedure and event in your Visual Basic application. If the procedure or event already contains error code, no additional error code is added.

The error code added to each procedure and event is shown below.

On Error GoTo VBT_ErrorLabel38448027

your code is here.

Exit Sub
VBT_ErrorLabel38448027:
    VBTErrorHandler "MYFORM.FRM", "MyProcedure", Error$, Err, Erl
     Exit Sub
End Sub

When an error is encountered, the form name, procedure name, error in verbage, error number, and line number where the error occurred are passed to a global error routine.  This error routine may be customized to either terminate the program or pass control back to the procedure where the error occurred.


Line Numbers

Click on any item above to see information on that item.

LINE NUMBERS? Yes, line numbers. For debugging compiled programs, there is just nothing like line numbers. Which error message would you perfer to see from a compiled program?

Illegal function call
or
Illegal function call in Line 53714.

It is best to add line numbers to a program just before compiling it to make sure all executable statements are numbered. VBTrace 96 begins numbering with 30,000. If you use line numbers in your program, use only numbers below 30,000 so VBTrace 96 will leave those lines alone.


SourceCodePrint

Click on any item above to see information on that item.

The Source Code Print feature of VBTrace 96 is a stand alone function and  is not directly related to VBTrace's 96 principal function of providing a detail runtime list of executed procedures. It is provided to you simply as an additional feature of VBTrace 96.

You may select different font names, sizes, and appearance parameters such as bold and italic for each of four areas of the source code listing, Headings, Sub and Function names, the source code itself, and Comments. You may also select to include only source code, only form and control descriptions, or both in the same listing.

There are two things to know about printing source code to the screen. Before printing to the screen, VBTrace 96 creates an image of the report and writes it to a disk file. This takes only a few seconds. Second, because the grid used to display the source code on the screen does not support multiple font sizes, listings printed to the screen use the same font size for each type of source code, Headings, Sub Names, Code, and Comments. Different font names and appearance parameters such as Bold and Italic are supported.

To Print Source Code:

1 	Select the form and code modules to print. Click on each file name to add or remove that file from the source listing. You may select all files by clicking on the Select All Files check box.

2 	Select the font name, font size, and appearance parameters such as bold or italic for each of four areas of the listing. Heading, Sub or Function Names, the actual Source Code, and Comments.

3 	Select whether to include only source code in the listing, only form and control descriptions, or both.

4 	If source code is included in the listing, you may elect to print the listing continuously or to start a new page for each sub and function.

5 	If form and control descriptions are included, you may elect to print the listing continuously or to start a new page for each form and control.

6 	Select whether to include reference line numbers in the listing. Line numbers which are part of the source code itself are always printed.

7 	Select whether to print the source code to the printer, the screen, or to a disk file. A file name is required when printing to a disk file.


DuplicateFilesManager

Click on any Item above to see information on that item.

The Duplicate Files Manager is a stand alone function and  is not directly related to VBTrace 96's principal function of providing a detail runtime list of executed procedures. It is provided to you simply as an additional feature of VBTrace 96.

The purpose of the Duplicate Files Manager is to locate duplicate files on your disk with the same name but a different size and/or date stamp and to assist you in removing all but the latest versions of those files from your disk.

The Duplicate Files Manager is specifically designed NOT to delete files. Its purpose is to locate duplicate files and make it easier for you to delete the files yourself.

The Duplicate Files Manager may be used in several ways to locate and remove duplicate files from your disk. How it is used depends on the type of files you are targeting.

There are basically two types of Windows related files on your disk.

1 	Files which normally belong in either the Windows or Windows\System directory. These are files with extensions such as DLL, VBX, FON, FOT, etc.

2 	Files which normally belong in the parent application's directory. These are files with extensions such as EXE, HLP, TXT, etc.

The following steps may be used to remove these and any other duplicate file types from your hard disk.

1 	Select an extension from the dropdown list or enter any other desired extension.

2 	Select the starting directory. This will normally be the root directory of the selected drive.

3 	Click on Begin Search.

 Remove duplicate files which normally reside in the Windows or System directories.

 Remove duplicate files which normally reside in the application's directory.

 Move Selected Files

 Rename Duplicate Files.

 Print The Duplicate Files List.


DuplicateMovingVBXFiles

Click any item above to see information on that item.

DLL and VBX files:

The object is to move the latest version of  VBX and DLL files to the Windows or Window\System directory and move all earlier versions of those files to a common directory. If no problems arise from this operation, the common directory and duplicate files may be deleted at a later date.

1 	Select Mark Latest to highlight the latest version of each file. The list may be edited by clicking on individual files.

2 	Select Move Marked to proceed to the Move Files dialog box.

3 	Set the drive and directory list boxes to point to the Windows or Windows\System directory and select Move Marked.

4 	After completing above step, you will be returned to the file list screen.

5 	Select Move Unmarked to return to the Move Files dialog box.

6 	Create a directory for the unmarked duplicates and select Move Unmarked. If no unexpected problems occur, you can delete this temporary directory and duplicate files at a later date.


DuplicateMoveHLPFiles

Click on any item above for information on that item.

EXE, HLP, and TXT files:

The object is to move the latest version of each duplicated file to a directory in the DOS Path and to rename earlier versions so that Windows cannot find them. This way you can be sure only the latest version of each file is available to Windows. If no problems arise from this operation, the earlier versions may be removed from your disk at a later date.

1 	Select Mark Lastest to highlight the latest version of each file. The list may be edited by clicking on individual files.

2 	Select Move Marked to proceed to the Move Files dialog box.

3 	Set the drive and directory list boxes to point to a directory in the DOS Path. Select Create A New Directory if necessary.

4 	Select Move Marked to move the highlighted files to the selected directory.

5 	After completion of the above step, you will be returned to the file list screen.

6 	Select Rename Duplicates.

7 	Enter a new extension for the duplicate files.

8 	Select OK to rename the duplicate files.

If no problems arise, files with this temporary extension may be safely removed from your disk at a later date.


DuplicateMoveFiles

Click on any item above to see information on that item.

The Move Duplicate Files dialog box allows you to move files which have been highlighted in the duplicate files list to any selected directory. Either the latest copy of each file or all earlier versions may be moved.  A new directory may be created for these files if necessary.

NOTE: The selected files are actually moved, not copied.


DuplicatesRename

Click on any item above to see information on that item.

The Rename Duplicate Files dialog box allows you to change the file name extension of all highlighted files in the duplicate files list. The purpose is to hide earlier versions of duplicated files from Windows so only the latest version will be used. By changing the extension rather than moving the file, the file can easily be recovered if a problem occurs when Windows cannot find it.


DuplicatePrint

Click on any item above to see information on that item.

The Print Duplicate Files dialog box allows you to print the duplicate files list before making changes in case it becomes necessary to restore all or part of the original configuration.


Time Required

Click on any item above for more information on that item.


Reformat

Click on any item above to see information on that item.

The Source Code Format feature of VBTrace 96 will read through selected forms and modules in your Visual Basic project and format the source code based on formatting rules you provide. The operation of your program is not changed in any way. Only the source code appearance is changed.

You can set a Global Margin which is the leftmost column in which any line of code may start. You can set the tab width in spaces. You can even choose the Basic keywords on which to tab and whether to tab left or tab right on each keyword.

If that sounds like a lot of setup work and decisions to make before you can get started, don't worry, the initial 'out of the box' setup should cover 95 percent of all situations.

Step By Step:

1 	Set the Global Margin. No line of code will start to the left of the Global Margin.

2 	Set the Tab Width in spaces. The initial setting is taken from the VB.INI file in your Windows directory.

3 	In the forms list, click on each form and code module in which the source code is to be formatted. Command buttons are provided to set or clear all forms.

4 	Make any desired changes to the keywords list. See Keyword List below before making these changes.

5 	Press the Start button.

After the code is formatted, examine the source code, make any desired changes to either the source code or format manager settings, and, if necessary, rerun the format manager. Correctly formatted source code can sometimes point out unexpected logic errors.

The Keyword List

There are two keyword lists. The top list contains words which cause the format manager to start the next line of code one tab to the right.  The bottom keyword list contains keywords which cause the format manager to start the line of code containing that keyword one tab to the left of the previous line of code.

You may add keywords to either list or remove keywords from either list. If you make changes to the keywords which cause your source code to be formatted incorrectly, press the Default command button to reset the keyword lists to the original configuration and rerun the format manager.

The red keywords are special cases which use the following rules.

1 	DIM, GLOBAL, STATIC: Always the Global Margin and one tab from the left edge of the form.

2 	FOR: Recognized only if the same line of code does not end with NEXT.

3 	IF and ELSEIF: Recognized only if the same line of code ends in THEN.

4 	SELECT CASE: The line of code following a Select Case must be tabed twice to the right since the line of code following the Select Case line will begin with CASE which will be tabed once to the left.

5 	END SELECT: Must be Tabed twice to the left rather than once.


Menus
Menus:

File

Operations

User

Setseup

Help


File Menu
File Menu:

SELECT A PROJECT:
Select a Visual Basic project to trace.

BACKUP / RESTORE PROJECT:
Back up the Visual Basic project before adding trace code.

EXIT VBTRACE 96:


Operations Menu
Operations Menu:

WATCH VARIABLES:
Brings up the Watch Variables Manager.

TRACE CODE:
Brings up the Trace Code Manager.

PROCEDURE SEARCH:
Search the VBTrace 96 report for a particular procedure or event.

REPORTS MANAGER:
Print a hard copy of the VBTrace 96 report as well as Cross Reference reports for variables and procedures.

SHOW HEADINGS COLLECTION:
Shows the available headings for the VBTrace listing.

CLEAR THE LISTING:
Clears the VBTrace 96 listing.

EXEMPTION EVENTS:
Allows you to flag procedures, events, or entire forms to not be included in the trace listing.

ERROR CODE:
Adds error code to each procedure and event in the current project.

LINE NUMBERS:
Adds line numbers to each executable statement in the current project.


User Menu
User Menu:

CONFIRM ON EXIT:
Prompts 'Are You Sure?' before exiting VBTrace.

AUTO RELOAD PROJECT:
Causes VBTrace to automatically reload the current project into the Visual Basic environment whenever changes are made to the source code. Otherwise, you will have to reload the project by hand.

MULTIPLE INSTANCES:
Determines if more than one instance of VBTrace can be active.

ENABLE WINDOWS SOUNDS:
Determines if Window's sounds such as Default Beep and Critical Stop should accompany VBTrace error messages.

PROMPT FOR BACKUP:
Check this option to have VBTrace prompt you to backup the project before VBTrace makes changes to the source code.

FUNCTION BAR SETUP:
Select the status and location of the Toolbar, Button Bar, and Status Bar.


Topic1
Setup Menu:

GRID FONT TYPE & SIZE:
The font type must be a fixed pitch type such as Courier New.

GRID TEXT COLOR:
Set the text color for the VBTrace 96 grid.

GRID BACKGROUND COLOR:
Set the background color for the VBTrace 96 grid.


Help Menu
Help Menu:

BALLOON HELP:
When Balloon Help is selected, moving the cursor over any item on the Toolbar or Status Bar will show information on that item.

HELP CONTENTS:
Brings up the contents page of this help file.

SEARCH HELP:
Search the help file keywords.

HOW TO USE HELP:
Information on how to use this help file.

ABOUT VBTRACE 96:
Copyright and registration information.


In Case Of A Problem
In Case Of A Problem:

Fortunately, there is very little that can go wrong with VBTrace 96.  If a problem should arise, deleting VBTRC96.DAT, VBTRC96.INI, and VBTRC96.BAS from the directory of the project being traced, and CURPROJ.INI from the VBTrace 96 directory will cure any problem.

If VBTrace 96 encounters a problem while writing to the trace file, VBTRC96.DAT, it will simply notify you of the problem, delete VBTRC96.DAT and shut off the trace function until the application being traced is exited and restarted.

If VBTrace 96 encounters a problem reading VBTRC96.DAT, it will notify you that a problem exists, but it will continue to read the file and show the VBTrace 96 display.  This may result in the VBTrace 96 display being scrambled, but simply restarting the application being traced will cure the problem.

Of course we want to be advised of any problems which should arise.
Free support is available through:
CIS 76560,51
AOL ChukStuart
cstuart@metronet.com


Registering VBTrace
Registering VBTrace 96:

You may examine VBTRACE 96 for 30 days at no cost.
If you decide to keep and use VBTrace 96, you must register it.

Registered copies are $49.00. Each registered copy is licensed for use on a single computer only.  A site license for copies of VBTrace 96 to use on additional computers at the same site may be purchased for $9.95 per computer.

***IMPORTANT NOTE:***
VBTrace 96 MUST be registered in the name shown on the Nag Screen. The Nag Screen is the initial yellow screen showing the days remaining in your evaluation period.

Registered copies of VBTrace 96 may be purchased in any of the following ways:

•	Via Compuserve:  GO SWREG.  The VBTrace 96 ID Number is 10749.

•	*** CREDIT CARD ORDERS ONLY - MC, Visa, Amex, or Discover ***
     Public (software) Library
     Voice 800-2424-PsL or 713-524-6394
     FAX to 713-524-6398
     CIS Email to 71355,470
Specify PsL product No. 11804.
The above numbers are for orders only.  Any questions about the status of the shipment of the order, product details, technical support, volume discounts, dealer pricing, site licenses, etc, must be directed to Chuck Stuart at one of the address shown below.

•	Order direct by sending cash, check, or money order to:
     Chuck Stuart
     2204 Camp David
     Mesquite, TX  75149
Allow 10 days for personal checks to clear.

You will receive a registration number via email within 48 hours of registering VBTrace 96. This registration number will automatically convert your trial copy of VBTrace 96 into a fully registered version. Maintenance updates will be made available free of charge for downloading from the various VB BBSs and forums and our www homepage.

Free support is available through
CIS 76560,51
AOL ChukStuart
cstuart@metronet.com

When you place your order you will be placed on our mailing list to receive notice of new products and updates.  Thank you for using VBTrace 96.


Topic1
Title


BackupBackup
Select this option to backup the project to the selected directory.


BackupBrowse
The Browse button allows you to view the disk directories as an aid to selecting or locating a backup directory.


BackupClose
Exits the Backup / Restore operation.


BackupDirectory
Select this option to backup all files in the project directory.


BackupHelp
Access on-line help for the Backup / Restore operation.


BackupPath
The path to the backup directory.


BackupProject
Select this option to backup only the files in the project MAK file.


BackupRestore
Select this option to restore the project files from the backup directory.


DuplicatesFindClose
Closes and exits the Duplicate Files Manager.


DuplicatesFindDirectory
Sets the drive and beginning directory for the search.


DuplicatesFindExtension
Select a file extension from the drop down list or enter any other desired file extension.


DuplicatesFindHelp
Brings up online help for the Duplicate File Manager.


DuplicatesFindList
Shows files with the selected extension as they are located.  Just here to give you something to watch while VBTrace 96 is finding the files


DuplicatesFindSearch
Begins a search for all files with the selected extension.


DuplicatesMarkClear
Removes highlights from files in the file list.


DuplicatesMarkClose
Closes this form and returns to the previous screen.


DuplicatesMarkDuplicates
Highlights duplicate copies of each file in the above list.


DuplicatesMarkFileList
Shows all duplicate files with the selected extension. Highlights either the latest copy of each duplicated file or the older versions depending upon which type has been selected using the buttons below.


DuplicatesMarkLatest
Highlights the latest copy of each file in the above list.


DuplicatesMarkMoveMarked
Displays the Move Files dialog box.


DuplicatesMarkMoveUnmarked
Displays the Move Files dialog box.


DuplicatesMarkPrint
Prints the duplicate files list.


DuplicatesMarkRenameMarked
Displays the Rename Files dialog box.


DuplicatesMarkRenameUnmarked
Displays the Rename Files dialog box.


DuplicatesMoveClose
Close and exit the Move Duplicate Files dialog box.


DuplicatesMoveCreateDirectory
Creates a new directory for the selected files.


DuplicatesMoveDirectories
Select the target drive and directory for the selected files.


DuplicatesMoveHelp
Brings up online Help for the Move Duplicate Files dialog box.


DuplicatesMoveMoveMarked
Starts the move files operation.


DuplicatesMoveOverWrite
Check here if you want existing files with the new extension to be overwritten. Otherwise, existing files with the new extension will be themselves renamed. HLP will be changed to HL1. DLL will be changed to DL1, etc.


DuplicatesPrintClose
Close and exit the Duplicate Files print dialog box.


DuplicatesPrintDestination
Select whether to print the duplicate files to the default printer or to a disk file. A file name must be entered when printing to a disk file.


DuplicatesPrintFileName
Enter a filename, drive, and directory when printing the duplicate files list to a disk file.


DuplicatesPrintFileTypes
Select the file type or types to print.


DuplicatesPrintHelp
Brings up online help.


DuplicatesPrintPrint
Prints the selected files.


DuplicatesPrintSetup
Brings up the printer setup dialog box.


DuplicatesRenameClose
Close and exit without performing the Rename operation.


DuplicatesRenameExtension
Enter the new extension for the earlier versions of the duplicated files.


DuplicatesRenameHelp
Brings up online help for the Raname Files dialog box.


DuplicatesRenameOK
Begins the Rename operation.


DuplicatesRenameOverwrite
Check here if you want existing files with the new extension to be overwritten. Otherwise, existing files with the new extension will be themselves renamed. HLP will be changed to HL1. DLL will be changed to DL1, etc.


DuplicatesRenameProgressBar
Shows the progress of the Extension Rename operation.


ErrorCodeAdd
Adds error code to the current project.


ErrorCodeButton
Add error code to each procedure in the project not already containing error code.


ErrorCodeClose
Exits the Error Code Manager.


ErrorCodeHelp
Access on-line help for the Error Code Manager.


ErrorCodeLineNumbers
Switches to the Line Number Manager.


ErrorCodeMode
Shows the current operation.


ErrorCodeProjectPath
Shows the name and path of the current project.


ErrorCodeRemove
Removes Error Code from the current project.


ErrorCodeStatus
Shows the progress of the Error Code operation.


ErrorCodeTraceCode
Switches to the Trace Code Manager.


ExceptionAddItem
Adds a new procedure, event, or form to the Exceptions list.


ExceptionAddRemove
Performs the selected operation.


ExceptionButton
Brings up the Procedures Exception Manager.


ExceptionClose
Exit the Procedures Exception Manager.


ExceptionHelp
Access on-line help for the Procedures Exception Manager..


ExceptionProcedureName
Enter the name of the procedure, event, or form to add or remove from the exceptions list. Press the drop down button to see a list of available choices.


ExceptionRemoveItem
Select this option to remove an item from the Exceptions List.


FormatClearSelections
Deselects All Forms And Modules In The Forms List.


FormatClose
Close And Exit The Source Code Format Manager.


FormatDedents
A Line Of Code Containing Any Of These Keywords Will Be Left Shifted The Number Of Spaces Shown In The 'Spaces Per Tab' Box.


FormatDefaults
Reset The Keyword Lists To The Factory Preset Keywords.


FormatFormsList
Shows The Selected Forms And Modules In Which The Source Code Will Be Formated.


FormatGlobalMargin
All Lines Of Code Will Begin A Mimimum Of This Number Of Spaces From The Left Edge Of The Form.


FormatHelp
Bring Up Online Help.


FormatIndents
After A Line Of Code Containing Any Of These Keywords, The Next Line Of Code Will Be Indented The Number Of Spaces Shown In The 'Spaces Per Tab' Box.


FormatSelectAllForms
Selects All Forms And Modules In The Forms List.


FormatStart
Start Formating The Source Code In The Selected Forms And Modules.


FormatTabWidth
The Number Of Spaces In Each Tab.


HeadingsAvailable
Shows the list of available headings for the trace listing.


HeadingsButton
Displays the Headings Collection.


HeadingsCancel
Cancels any changes and exits the Headings Manager.


HeadingsDelete
Removes the selected heading from the Headings Collection.


HeadingsHelp
Access on-line help for the Headings Collection.


HeadingsOK
Changes to the selected heading and exits the Headings Manager.


Installing VBTrace
Installing VBTrace 96:

1 	Create a directory for VBTrace 96.

2 	Using PKUNZIP, unzip VBTRACE.ZIP into the directory created in step 1.

3 	From Windows Program Manager, select File, New, and Program Item to install the VBTrace 96 icon into the desired program group.

After installation, the VBTrace 96 directory should contain the following files.

VBTRACE.EXE	The VBTrace 96 executable.
VBTRACE.HLP	This Help file.
VBTRACE.BAS	The code module added to the project being traced.
VBCTL3D.VBX	Third party control for 3D appearance.
SSDATA2.VBX	Grid control from Sheridan Software.

IMPORTANT NOTE:
VBTrace 96 requires the latest versions of SSDATA2.VBX and VBCTL3D.VBX. If you have earlier versions on your disk, you must replace them with the versions in VBTRACE.ZIP. Later versions are OK.

If you have no other programs which require SSDATA2.VBX or VBCTL3D.VBX, you may leave them in the VBTrace 96 directory. Otherwise, they should be moved to the Windows\System directory.

SSDATA2.VBX is the Data Widgets grid control from Sheridan Software.

VBCTL3D.VBX is a shareware control used to give VBTrace 96 a 3D appearance. The file name is VB3D.ZIP. It may be downloaded from the MSBASIC or VBPJ forums on CIS or from CICA on the Internet.


LineNumbersAdd
Adds Line Numbers to each executable statement in the current project.


LineNumbersClose
Exits the Line Number Manager.


LineNumbersErrorCode
Switches to the Error Code Manager.


LineNumbersHelp
Access on-line help for the Line Number Manager.


LineNumbersMode
Shows the current operation.


LineNumbersProjectPath
Shows the name and path of the current project.


LineNumbersRemove
Removes Line Numbers greater than 30,000 from the current project.


LineNumbersStatus
Shows the status of the Line Number operation.


LineNumbersTraceCode
Switches to the Trace Code Manager.


Quick Start
VBTrace 96 Quick Start:

Quick Start allows you to get VBTrace 96 up and running without the mundane chore of actually having to read instructions.  It is assumed that VBTrace 96 has been installed and the VBTrace 96 icon has been added to the desired program group.

1 	To start VBTrace 96, double click on the VBTrace 96 icon on the Windows Desktop.

2 	VBTrace 96 will automatically display the Open File common dialog box from which you may select a Visual Basic project to trace.

3 	VBTrace 96 will prompt you to backup the selected project before adding trace code. It is recommended that you select Yes.

4 	After backing up the selected project, select Yes to add trace code to the project.

5 	Click on the VB button on the toolbar to minimize VBTrace 96 and load the selected project into the Visual Basic environment.

6 	Start the application being traced.

At any time, you can switch to VBTrace 96, view the trace listing, then switch back to the application being traced.  You may switch back and forth as often as necessary.  The VBTrace 96 listing will continue to grow until you exit the application being traced or use the Clear Listing button on the VBTrace 96 Toolbar.


RemoveItem
Select this option to remove an item from the Exceptions list.


ReportBuild
Select this button to 'build' the cross reference reports. Once the reports have been created, they can be printed in the desired format.


ReportButton
Brings up the Report Manager.


ReportClose
Exits the Report Manager.


ReportDisk
Causes the selected report to be printed a disk file.


ReportHelp
Brings up on-line help for the Report Manager.


ReportIncludeResources
Causes the information from the Status Bar to be included in the Report.


ReportPrint
Prints the selected report to the selected device.


ReportPrinter
Causes the selected report to be printed to the printer.


ReportPrinterSetup
Brings up the Printer Setup dialog box.


ReportProceduresX
Selects the Procedures Cross Reference report to be printed.


ReportScreen
Causes the selected report to be printed to the screen.


ReportScreenSetup
Sets the font, size, and appearance for reports to the screen.


ReportStatus
Shows the report print progress.


ReportTraceReport
Selects the trace listing to be printed either to a printer or to a disk file. The trace listing cannot be printed to the screen.


ReportUnreferencedP
Check this box to have the Procedures Cross Reference report show only unreferenced procedures.


ReportUnreferencedV
Check this box to have the Variables Cross Reference report show only unreferenced variables.


ReportVariablesX
Selects the Variables Cross Reference report to be printed.


ScreenBackupRestoreButton
Backup or Restore the project files.


ScreenClearDisplayButton
Clears the trace listing. The current project and column configuration remain unchanged.


ScreenDiskSpace
Shows the current drive ID and the amount of disk space available on that drive.


ScreenDisplayTitleBar
The Title Bar shows the name of the currently selected project followed by the date and time the current trace listing was created.


ScreenErrorCodeButton
Brings up the Error Code Manager. The Error Code Manager can be used to add error code to, or remove error code from, each procedure in a project.


ScreenExceptionsButton
Brings up the Procedure Exceptions Manager. The Procedure Exceptions Manager allows you to exclude procedures or entire forms from the trace display.


ScreenExitButton
Closes all files, unloads all forms, and exits VBTrace 96


ScreenFindDuplicatesButton
Finds and helps remove duplicate files from your hard disk.


ScreenFormsCount
Shows the number of forms loaded as each procedure is entered and exited.


ScreenGDIMemory
Shows the percentage of GDI memory available from the original pool of 128K.   Under 20% can affect program stability.  Reduce the amount of GDI memory usage by reducing the number of device contexts, pens, brushes, regions, and bitmaps.


ScreenGlobalMemory
Shows the amount of Global Heap memory available.  Global Heap memory is the total memory available to all Windows programs.  It does not include disk or swap file memory.


ScreenHorizontalScrollBar
The horizontal scroll bar appears whenever the width of the display exceeds the width of the display area of the screen.


ScreenLineCount
Shows the total number of lines in the current trace listing.


ScreenLineNumberButton
Brings up the Line Number Manager. The Line Number Manager is used to add line numbers just prior to compiling to facilitate locating errors in a compiled program.


ScreenLineNumberColumn
Line numbers are used to trace a procedure forward and backward through the trace listing.


ScreenLineNumbers
Total number of lines in the trace display.


ScreenMenuBar
The Menu Bar.


ScreenMousedHelpButton
Displays the following message:
For Information On Items On The Toolbar And Status Bar, Select 'Balloon Help' From The Help Menu, Then Move The Cursor Over The Desired Item. For Help On Other Forms, Press F1 While The Form Is Visible, Then Move The Cursor Over Each Item On The Form To See Information On That Item.


ScreenOnLineHelpButton
Access on-line help.


ScreenPreviousLineNumberColumn
The Previous Line column shows the number of the line where a procedure was previously referenced.  It is used to trace a procedure backward through the trace listing.


ScreenProcedureNameColumn
The Procedure Name Column is always the rightmost column in the trace display and is the only required column.  It cannot be moved, changed,  or deleted.


ScreenProcedureSearchButton
Brings up the Procedure Search form.


ScreenReportsButton
Prints the cross reference reports.


ScreenResetDefaultsButton
Resets the Headings Collection and Watch Variables Collection to the default configuration.


ScreenSelectHeadingButton
This is one of two default column configurations.  Select column configurations by viewing the Headings collection.  Click on each column for more information on that column.


ScreenSelectProjectButton
Select a Visual Basic project to trace.


ScreenSourcePrintButton
Prints formatted listings of your project's source code.


ScreenTimeColumn
The Time column shows the time in seconds and tenths of seconds required to execute a procedure or group of procedures.  The Time is shown only on procedure exit lines.


ScreenTimeRequiredButton
Displays the Procedures By Time Required report.


ScreenTimesEnteredColumn
The Times Entered column shows the number of times a procedure has been entered.  If the Times Entered count exceeds the Times Exited count by more than one, the procedure is being called recursively.


ScreenTimesExitedColumn
The Times Exited column shows the number of times a procedure has been exited.  If the Times Entered count exceeds the Times Exited count by more than one, the procedure is being called recursively.


ScreenTraceCodeButton
Brings up the Trace Code Manager.


GDIMemory
Shows the amount of USER memory available from an original pool of 64K.   Under 20% can affect program stability.  Reduce the amount of USER memory usage by reducing the number of windows, forms, and menus.


ScreenVBButton
Minimizes VBTrace 96 and does one of the following:
1. If VB is not loaded, loads VB and then loads the current project.
2. If VB is loaded, loads the current project.


ScreenVerticalScrollBar
The vertical scroll bar appears whenever the number of lines in the trace listing exceed the number of lines which may be displayed on the screen.


ScreenWatchVariablesButton
Brings up the Watch Variables Manager which can be used to add additional columns to the trace display.


SearchBeginSearch
Begin the procedure search.  After a match is found, press F3 to find the next match.  Any other key will stop the search.


SearchCancelProcedureSearch
Cancels the Procedure Search operation.


SearchMatchCase
Selects only procedures which exactly match the case of the search string.


SearchMatchWholeWord
Finds only procedure names which exactly match the name in the search box, otherwise all procedures which begin with the name in the search box will be displayed.


SearchProcedureName
Enter the name of the procedure for which to search. Press the drop down button to view a list of available procedures.


SearchProcedureSearchHelp
Brings up on-line help for the Procedure Search operation.


SourceClose
Click here to close and exit the Source Code function.


SourceCodeAttributes
Selects the font name, font size, and appearance attributes such as bold or italic for the Source Code in the source code listing.


SourceCommentsAttributes
Selects the font name, font size, and appearance attributes such as bold or italic for the Comments in the source code listing.


SourceDiskFileName
Click here to enter a file name when printing the source code listing to a disk file.


Topic1
Shows all forms and/or code modules in the current project.


SourceFileTypes
Selects whether forms, code modules, or both will appear in the file list.


SourceHeadingAttributes
Selects the font name, font size, and appearance attributes such as bold or italic for the Headings in the source code listing.


SourceHelp
Click here to bring up online help.


SourceLineNumbers
Check this box to include reference line numbers in the source listing.


SourcePageOnControl
Select this option button to begin each control description on a new page.


SourcePageOnForm
Select this option button to begin each form description on a new page.


SourcePageOnForm1
Select this option button to begin each form on a new page.


SourcePageOnProcedure
Select this button to begin each procedure on a new page.


SourcePrint
Click here to begin printing the source code listing.


SourcePrintCode
Check this box to include source code in the listing.


SourcePrintControls
Check this box to include form and control descriptions in the source listing.


SourcePrintToDisk
Select this option button to print the source code listing to a disk file.


SourcePrintToPrinter
Select this option button to print the source code listing to a printer.


SourcePrintToScreen
Select this option button to print the source code listing to the screen.


SourceSelectAll
Selects all forms and code modules shown in the files list to be included in the source listing.


SourceSetup
Click here to select or change printer options.


SourceStatusBar
Gives a visual indication of the progress when printing the source code listing to the printer or to a disk file.


SourceSubNameAttributes
Selects the font name, font size, and appearance attributes such as bold or italic for the Sub and Function Names in the source code listing.


TimeRequiredCalled
Click on this column to sort the report by the number of times each procedure was called.


TimeRequiredClose
Click to close and exit this report.


TimeRequiredHelp
Click to access online help for this report.


Topic1
Click to print the report to the printer.


TimeRequiredProcedureName
Click on this column to sort the report by Procedure Name.


TimeRequiredTime
Click on this column to sort the report by the time required to execute procedures.


Topic1
Title


TraceCodeAdd
Adds Trace Code to each procedure in the selected Visible Basic project.  Also adds the code module, VBTRACE.BAS, to the project MAK file..


TraceCodeButton
Brings up the Trace Code Manager.


TraceCodeClose
Exit the Trace Code Manager.


TraceCodeErrorCode
Switches to the Error Code Manager.


TraceCodeExit
Exits the Trace Code Manager.


TraceCodeHelp
Brings up on-line help for the Trace Code Manager.


TraceCodelineNumbers
Switches to the Line Number Manager.


TraceCodeMode
Shows the current operation.


TraceCodeProjectPath
Shows the name and path of the current project.


TraceCodeRemove
Removes all trace code and the code module, VBTRACE.BAS, from the selected Visual Basic project.


TraceCodeStatus
Progress gauge for the Trace Code operation.


WatchVariableAdd
Click to add a new Watch Variable to the Watch Variables Collection.


WatchVariableCenter
Causes the data in this column to be centered in the column.


WatchVariableClose
Exits the Watch Variables Manager.


WatchVariableFormat
The format string for the data to appear in this column. This is the only optional entry.


WatchVariableHeading
The column heading to appear in the trace listing..


WatchVariableHelp
Access on-line help for the Watch Variables Manager.


WatchVariableIndex
If the selected variable to watch is an array variable, enter the index. for that variable. The index must be a numeric literal or else a variable which is global in scope.


WatchVariableLeft
Causes the data in this column to be left justified.


WatchVariableModify
Click to modify an existing watch variable.


WatchVariableName
Select the variable to watch from the list of Global Variables.


WatchVariablePosition
The column in which this watch variable is to appear. Columns are numbered from left to right beginning with column one.


WatchVariableRight
Causes the data in this column to be right justified.


WatchVariablesButton
Brings up the Watch Variables Manager.


WatchVariableStatus
Enter 1 to add this variable to the current trace listing. Enter 0 to remove this variable from the current trace listing. This value may be changed at any time.


WatchVariableWidth
The width of the column in characters.


batch mode

In batch mode, the application being traced is started and run to its normal conclusion   VBTrace is then started to examine the VBTrace listing in its entirety.  The advantage of using batch mode is the application being traced does not have to share Windows resources with VBTrace.


event driven

Most programming languages, including all previous versions of BASIC, produce procedure driven programs.  Procedure driven programs follow a predefined path determined by the programmer at design time. The logic flow in programs written in an event driven language, such as Visual Basic, is determined at run time by user actions such as clicking a mouse or pressing a key.  The programmer has very little control over program flow and the order in which procedure are executed..


exit point

The exit point of a procedure is usually the End Sub or End Function statement at the end of the procedure.  It can also be one or more Exit Sub or Exit Function statement anywhere in the procedure..  VBTrace can also handle in-line Exit statements such as "If SomeCondition then Exit Sub".


float

When VBTrace is minimized, it is assigned the Topmost window position so it will not be covered by any other window.


interactively

In interactive mode, both VBTrace and the application being traced are active at the same time.  The advantage in using interactive mode is receiving immediate feedback from any changes made to your application.  The disadvantage is having to share Windows resources with VBTrace.


nested

The number of procedures open at the time this procedure was called.


on the fly

When columns are added or removed from the VBTrace listing, code lines are actual inserted into the VBTRACE.BAS code module to add or remove the selected items from the listing.  You can examine the VBTRACE.BAS code module in your program to see the results of this programming on the fly.


recursively

'Recursive' means that the procedure was entered but not yet exited when it was called again.  Usually by a procedure which this procedure has called.  This is an accepted programming technique and a valid condition if you expect it to happen.  If not, it usually indicates an error in program logic flow..


VBTRACE.BAS

VBTrace adds the VBTRACE.BAS code module to your project.  During execution of your program, VBTRACE.BAS writes the name of each procedure and the name and value of any variables being tracked to the VBTrace file, VBTRACE.DAT. Do not coay VBTRACE.BAS to your application. It must be configured and added by VBTrace.


VBTRACE.DAT

VBTRACE.DAT is a standard, relative record file containing the trace data created by your program.